<!DOCTYPE html>
<html>
<head lang="en">
    <head lang="en">
        <meta charset="UTF-8">
        <title>{{$data->title}}</title>
        <link rel="stylesheet" href="{{asset('css/reset.css')}}"/>
        <link rel="stylesheet" href="{{asset('css/index.css')}}"/>
        <meta name="viewport" content="width=device-width,initial-scale=1.0,maximum-scale=1.0,minimum-scale=1.0,user-scalable=no">
        <meta name="keywords" content="{{$keywords}}"/>
        <meta name="description" content="{{$data->smalltext}}"/>
        <meta name="baidu-site-verification" content="x1XYMzRXUS" />
    </head>
<body>

@include('common.header2')

<section class="article">
    <article>
        <h2>{{$data->title}}</h2>
        <p class="info"><span>{{date('Y-m-d',$data['newstime'])}}</span><span>来源：好头发网</span></p>
        <div>
            {!! $data['newstext'] !!}
        </div>
        <p class="span_info">标签：
            @if($keyArr)
                @foreach($keyArr as $key => $value)
                    <a href="{{url('search?str='.$value.'&class_id='.$parent_id)}}">{{$value}}</a>
                @endforeach
            @endif
        </p>
    </article>
</section>

<section class="advertisement">
    <section>
        <p><span>8年</span>生发经验，头发健康领域专家</p>
        <p style="font-size:12px; color:#999; text-align:center; line-height:60px; width:100%">
            <img style="vertical-align:middle; height:20px; position:relative; top:-3px;" src="http://www.haotoufa.com/d/file/news/nanxingrewen/renqun.png" alt="QQ群">
            加入官方脱发交流<span style="font-size:14px; color:#1791dd;">QQ群:86809880</span>&nbsp;&nbsp;<span style="font-size:12px; color:#333;">一起怼脱发！</span>
        </p>
        <!-- 好头发淘宝商城 -->
        <!-- <div class="list-member">
            <div class="list-left">
                <p>好头发</p>
                <p>扫描二维码关注</p>
                <p>这是一个让你头发变好的公众号</p>
                <p>微信公众号ID:haotoufa</p>
            </div>
            <div class="list-right">
                <img src="{{asset('image/haotoufa_code.png')}}">
            </div>
        </div>
        <div class="list-member">
            <div class="list-left">
                <p>好头发淘宝商城</p>
                <p>点击图片直达</p>
                <p>你身边的防脱生发专家</p>
                <p>
                    <a style="color: #333;font-size: 13px;margin-top: 12px;" href="https://haotoufa.taobao.com" rel="nofollow">haotoufa.taobao.com</a>
                </p>
            </div>
            <div class="list-right">
                <a href="https://haotoufa.taobao.com">
                    <img src="{{asset('image/haotoufabai_code.png')}}" rel="nofollow">
                </a>
            </div>
        </div> -->
    </section>
</section>

<section id="contentBox">
    <p class="contentBox_top">
        <span>评论</span><span>({{$comment['comment_count']}}条)</span>
    </p>
    <div class="contentBox_main">
        @foreach($comment['comment_list'] as $k => $v)
        <div class="contentBox_main_member">
            <p class="contentBox_main_member_top"><span>{{$v['tel']}}</span><span><img width="20" height="20" src="{{asset('image/praise.png')}}"><span>{{$v['zan']}}</span></span></p>
            <p class="contentBox_main_member_content">{{$v['content']}}</p>
            <p class="contentBox_main_member_bottom">{{$v['create_time']}}</p>
        </div>
        @endforeach
        @if($comment['comment_list'])
            <a href="{{url('comment/'.$class_id)}}">查看全部</a>
        @else
            <a style="width: 150px;" href="{{url('comment_add/'.$class_id)}}">我来发表第一条评论</a>
        @endif
    </div>
</section>

<section class="relation">
    <div><p>相关阅读</p></div>
    <section class="main_show column">
        <div class="list">
            @foreach($abouts as $k => $v)
                @include('common.list_member')
            @endforeach
        </div>
    </section>
</section>

<img class="adverImg" src="{{asset('image/advertisement2.png')}}" onClick="location.href='http://bbs.haotoufa.com/coupon/price.html'">
<section class="relation">
    <div><p>最新推荐</p></div>
    <section class="main_show column arc">
        <div class="list">
            @foreach($news as $k => $v)
                @include('common.list_member')
            @endforeach
        </div>
    </section>
</section>

@include('common.footer')
<script>
  $(".article img").css("height","auto");
  $('.contentBox_main').on('click','.contentBox_main_member',function () {
      window.location.href = '{{url('comment/'.$class_id)}}';
  });
</script>
</body>
</html>